; ModuleID = 't3.bt1rl0f3-cgu.0'
source_filename = "t3.bt1rl0f3-cgu.0"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"core::fmt::Formatter" = type { [0 x i64], { i64, i64 }, [0 x i64], { i64, i64 }, [0 x i64], { {}*, [3 x i64]* }, [0 x i32], i32, [0 x i32], i32, [0 x i8], i8, [7 x i8] }
%"core::fmt::Arguments" = type { [0 x i64], { [0 x { [0 x i8]*, i64 }]*, i64 }, [0 x i64], { i64*, i64 }, [0 x i64], { [0 x { i8*, i8* }]*, i64 }, [0 x i64] }
%"unwind::libunwind::_Unwind_Exception" = type { [0 x i64], i64, [0 x i64], void (i32, %"unwind::libunwind::_Unwind_Exception"*)*, [0 x i64], [6 x i64], [0 x i64] }
%"unwind::libunwind::_Unwind_Context" = type { [0 x i8] }

@vtable.0 = private unnamed_addr constant { void (i8**)*, i64, i64, i32 (i8**)*, i32 (i8**)*, i32 (i8**)* } { void (i8**)* @_ZN4core3ptr13drop_in_place17h0e7f2b3546d313caE, i64 8, i64 8, i32 (i8**)* @"_ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17h333ea9d4a60716ebE", i32 (i8**)* @"_ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17h333ea9d4a60716ebE", i32 (i8**)* @"_ZN4core3ops8function6FnOnce40call_once$u7b$$u7b$vtable.shim$u7d$$u7d$17hac75854626d876caE" }, align 8
@alloc1 = private unnamed_addr constant <{ [10 x i8] }> <{ [10 x i8] c"test_box: " }>, align 1
@alloc2 = private unnamed_addr constant <{ [1 x i8] }> <{ [1 x i8] c"\0A" }>, align 1
@alloc3 = private unnamed_addr constant <{ i8*, [8 x i8], i8*, [8 x i8] }> <{ i8* getelementptr inbounds (<{ [10 x i8] }>, <{ [10 x i8] }>* @alloc1, i32 0, i32 0, i32 0), [8 x i8] c"\0A\00\00\00\00\00\00\00", i8* getelementptr inbounds (<{ [1 x i8] }>, <{ [1 x i8] }>* @alloc2, i32 0, i32 0, i32 0), [8 x i8] c"\01\00\00\00\00\00\00\00" }>, align 8

; std::rt::lang_start
; Function Attrs: nonlazybind uwtable
define hidden i64 @_ZN3std2rt10lang_start17h3a07166bbe928f28E(void ()* nonnull %main, i64 %argc, i8** %argv) unnamed_addr #0 {
start:
  %_7 = alloca i8*, align 8
  %0 = bitcast i8** %_7 to i8*
  call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %0)
  %1 = bitcast i8** %_7 to void ()**
  store void ()* %main, void ()** %1, align 8
  %_4.0 = bitcast i8** %_7 to {}*
; call std::rt::lang_start_internal
  %2 = call i64 @_ZN3std2rt19lang_start_internal17hf4abd869024c3270E({}* nonnull align 1 %_4.0, [3 x i64]* noalias readonly align 8 dereferenceable(24) bitcast ({ void (i8**)*, i64, i64, i32 (i8**)*, i32 (i8**)*, i32 (i8**)* }* @vtable.0 to [3 x i64]*), i64 %argc, i8** %argv)
  call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %0)
  ret i64 %2
}

; std::rt::lang_start::{{closure}}
; Function Attrs: nonlazybind uwtable
define internal i32 @"_ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17h333ea9d4a60716ebE"(i8** noalias nocapture readonly align 8 dereferenceable(8) %_1) unnamed_addr #0 {
start:
  %0 = bitcast i8** %_1 to void ()**
  %_3 = load void ()*, void ()** %0, align 8, !nonnull !3
  tail call void %_3()
  ret i32 0
}

; core::fmt::num::<impl core::fmt::Debug for i32>::fmt
; Function Attrs: inlinehint nonlazybind uwtable
define internal zeroext i1 @"_ZN4core3fmt3num50_$LT$impl$u20$core..fmt..Debug$u20$for$u20$i32$GT$3fmt17hb6b500d511226317E"(i32* noalias readonly align 4 dereferenceable(4) %self, %"core::fmt::Formatter"* align 8 dereferenceable(64) %f) unnamed_addr #1 {
start:
; call core::fmt::Formatter::debug_lower_hex
  %_3 = tail call zeroext i1 @_ZN4core3fmt9Formatter15debug_lower_hex17h68b810b761abe09bE(%"core::fmt::Formatter"* noalias nonnull readonly align 8 dereferenceable(64) %f)
  br i1 %_3, label %bb3, label %bb2

bb2:                                              ; preds = %start
; call core::fmt::Formatter::debug_upper_hex
  %_7 = tail call zeroext i1 @_ZN4core3fmt9Formatter15debug_upper_hex17h20623f52650bb644E(%"core::fmt::Formatter"* noalias nonnull readonly align 8 dereferenceable(64) %f)
  br i1 %_7, label %bb7, label %bb6

bb3:                                              ; preds = %start
; call core::fmt::num::<impl core::fmt::LowerHex for i32>::fmt
  %0 = tail call zeroext i1 @"_ZN4core3fmt3num53_$LT$impl$u20$core..fmt..LowerHex$u20$for$u20$i32$GT$3fmt17h19ab7be5b0fb7587E"(i32* noalias nonnull readonly align 4 dereferenceable(4) %self, %"core::fmt::Formatter"* nonnull align 8 dereferenceable(64) %f)
  br label %bb11

bb6:                                              ; preds = %bb2
; call core::fmt::num::imp::<impl core::fmt::Display for i32>::fmt
  %1 = tail call zeroext i1 @"_ZN4core3fmt3num3imp52_$LT$impl$u20$core..fmt..Display$u20$for$u20$i32$GT$3fmt17hbb27e86dfb8ce1d4E"(i32* noalias nonnull readonly align 4 dereferenceable(4) %self, %"core::fmt::Formatter"* nonnull align 8 dereferenceable(64) %f)
  br label %bb11

bb7:                                              ; preds = %bb2
; call core::fmt::num::<impl core::fmt::UpperHex for i32>::fmt
  %2 = tail call zeroext i1 @"_ZN4core3fmt3num53_$LT$impl$u20$core..fmt..UpperHex$u20$for$u20$i32$GT$3fmt17hd8a7bd4ba29743b9E"(i32* noalias nonnull readonly align 4 dereferenceable(4) %self, %"core::fmt::Formatter"* nonnull align 8 dereferenceable(64) %f)
  br label %bb11

bb11:                                             ; preds = %bb7, %bb6, %bb3
  %.0.in = phi i1 [ %0, %bb3 ], [ %2, %bb7 ], [ %1, %bb6 ]
  ret i1 %.0.in
}

; core::ops::function::FnOnce::call_once{{vtable.shim}}
; Function Attrs: nonlazybind uwtable
define internal i32 @"_ZN4core3ops8function6FnOnce40call_once$u7b$$u7b$vtable.shim$u7d$$u7d$17hac75854626d876caE"(i8** nocapture readonly %_1) unnamed_addr #0 personality i32 (i32, i32, i64, %"unwind::libunwind::_Unwind_Exception"*, %"unwind::libunwind::_Unwind_Context"*)* @rust_eh_personality {
start:
  %0 = bitcast i8** %_1 to void ()**
  %1 = load void ()*, void ()** %0, align 8, !nonnull !3
  tail call void %1(), !noalias !4
  ret i32 0
}

; core::ptr::drop_in_place
; Function Attrs: nounwind nonlazybind uwtable
define internal fastcc void @_ZN4core3ptr13drop_in_place17h045df3b7c654ef18E(i32* %_1.val) unnamed_addr #2 personality i32 (i32, i32, i64, %"unwind::libunwind::_Unwind_Exception"*, %"unwind::libunwind::_Unwind_Context"*)* @rust_eh_personality {
start:
  %_2.i.i = bitcast i32* %_1.val to i8*
  tail call void @__rust_dealloc(i8* nonnull %_2.i.i, i64 4, i64 4) #7
  ret void
}

; core::ptr::drop_in_place
; Function Attrs: norecurse nounwind nonlazybind readnone uwtable
define internal void @_ZN4core3ptr13drop_in_place17h0e7f2b3546d313caE(i8** nocapture %_1) unnamed_addr #3 {
start:
  ret void
}

; t3::main
; Function Attrs: nonlazybind uwtable
define internal void @_ZN2t34main17h33660e99b2ecbe28E() unnamed_addr #0 personality i32 (i32, i32, i64, %"unwind::libunwind::_Unwind_Exception"*, %"unwind::libunwind::_Unwind_Context"*)* @rust_eh_personality {
start:
  %_19.i = alloca [1 x { i8*, i8* }], align 8
  %_12.i = alloca %"core::fmt::Arguments", align 8
  %0 = tail call dereferenceable_or_null(4) i8* @__rust_alloc(i64 4, i64 4) #7
  %1 = icmp eq i8* %0, null
  br i1 %1, label %bb3.i.i.i, label %"_ZN5alloc5boxed12Box$LT$T$GT$3new17h49bd786f9703107dE.exit.i"

bb3.i.i.i:                                        ; preds = %start
; call alloc::alloc::handle_alloc_error
  tail call void @_ZN5alloc5alloc18handle_alloc_error17he602a36a7d59d201E(i64 4, i64 4) #7
  unreachable

"_ZN5alloc5boxed12Box$LT$T$GT$3new17h49bd786f9703107dE.exit.i": ; preds = %start
  %2 = bitcast i8* %0 to i32*
  store i32 5, i32* %2, align 4
  %3 = tail call dereferenceable_or_null(4) i8* @__rust_alloc(i64 4, i64 4) #7
  %4 = icmp eq i8* %3, null
  br i1 %4, label %bb3.i.i2.i, label %bb10.i

bb3.i.i2.i:                                       ; preds = %"_ZN5alloc5boxed12Box$LT$T$GT$3new17h49bd786f9703107dE.exit.i"
; call alloc::alloc::handle_alloc_error
  tail call void @_ZN5alloc5alloc18handle_alloc_error17he602a36a7d59d201E(i64 4, i64 4) #7
  unreachable

bb1.i:                                            ; preds = %bb10.i
  %5 = landingpad { i8*, i32 }
          cleanup
; call core::ptr::drop_in_place
  call fastcc void @_ZN4core3ptr13drop_in_place17h045df3b7c654ef18E(i32* nonnull %6) #8
  resume { i8*, i32 } %5

bb10.i:                                           ; preds = %"_ZN5alloc5boxed12Box$LT$T$GT$3new17h49bd786f9703107dE.exit.i"
  %6 = bitcast i8* %3 to i32*
  store i32 6, i32* %6, align 4
  %7 = bitcast %"core::fmt::Arguments"* %_12.i to i8*
  call void @llvm.lifetime.start.p0i8(i64 48, i8* nonnull %7)
  %8 = bitcast [1 x { i8*, i8* }]* %_19.i to i8*
  call void @llvm.lifetime.start.p0i8(i64 16, i8* nonnull %8)
  %9 = getelementptr inbounds [1 x { i8*, i8* }], [1 x { i8*, i8* }]* %_19.i, i64 0, i64 0, i32 0
  store i8* %0, i8** %9, align 8
  %10 = getelementptr inbounds [1 x { i8*, i8* }], [1 x { i8*, i8* }]* %_19.i, i64 0, i64 0, i32 1
  store i8* bitcast (i1 (i32*, %"core::fmt::Formatter"*)* @"_ZN4core3fmt3num50_$LT$impl$u20$core..fmt..Debug$u20$for$u20$i32$GT$3fmt17hb6b500d511226317E" to i8*), i8** %10, align 8
  %11 = bitcast %"core::fmt::Arguments"* %_12.i to [0 x { [0 x i8]*, i64 }]**
  store [0 x { [0 x i8]*, i64 }]* bitcast (<{ i8*, [8 x i8], i8*, [8 x i8] }>* @alloc3 to [0 x { [0 x i8]*, i64 }]*), [0 x { [0 x i8]*, i64 }]** %11, align 8, !alias.scope !7, !noalias !10
  %12 = getelementptr inbounds %"core::fmt::Arguments", %"core::fmt::Arguments"* %_12.i, i64 0, i32 1, i32 1
  store i64 2, i64* %12, align 8, !alias.scope !7, !noalias !10
  %13 = getelementptr inbounds %"core::fmt::Arguments", %"core::fmt::Arguments"* %_12.i, i64 0, i32 3, i32 0
  store i64* null, i64** %13, align 8, !alias.scope !7, !noalias !10
  %14 = getelementptr inbounds %"core::fmt::Arguments", %"core::fmt::Arguments"* %_12.i, i64 0, i32 5, i32 0
  %15 = bitcast [0 x { i8*, i8* }]** %14 to [1 x { i8*, i8* }]**
  store [1 x { i8*, i8* }]* %_19.i, [1 x { i8*, i8* }]** %15, align 8, !alias.scope !7, !noalias !10
  %16 = getelementptr inbounds %"core::fmt::Arguments", %"core::fmt::Arguments"* %_12.i, i64 0, i32 5, i32 1
  store i64 1, i64* %16, align 8, !alias.scope !7, !noalias !10
; invoke std::io::stdio::_print
  invoke void @_ZN3std2io5stdio6_print17h35ebd65662fa8b15E(%"core::fmt::Arguments"* noalias nocapture nonnull dereferenceable(48) %_12.i)
          to label %_ZN2t38test_box17h1a184087ce0c10bbE.exit unwind label %bb1.i

_ZN2t38test_box17h1a184087ce0c10bbE.exit:         ; preds = %bb10.i
  call void @llvm.lifetime.end.p0i8(i64 48, i8* nonnull %7)
  call void @llvm.lifetime.end.p0i8(i64 16, i8* nonnull %8)
  call void @__rust_dealloc(i8* nonnull %3, i64 4, i64 4) #7
  ret void
}

; Function Attrs: argmemonly nounwind willreturn
declare void @llvm.lifetime.start.p0i8(i64 immarg, i8* nocapture) #4

; std::rt::lang_start_internal
; Function Attrs: nonlazybind uwtable
declare i64 @_ZN3std2rt19lang_start_internal17hf4abd869024c3270E({}* nonnull align 1, [3 x i64]* noalias readonly align 8 dereferenceable(24), i64, i8**) unnamed_addr #0

; Function Attrs: argmemonly nounwind willreturn
declare void @llvm.lifetime.end.p0i8(i64 immarg, i8* nocapture) #4

; core::fmt::Formatter::debug_lower_hex
; Function Attrs: nonlazybind uwtable
declare zeroext i1 @_ZN4core3fmt9Formatter15debug_lower_hex17h68b810b761abe09bE(%"core::fmt::Formatter"* noalias readonly align 8 dereferenceable(64)) unnamed_addr #0

; core::fmt::num::<impl core::fmt::LowerHex for i32>::fmt
; Function Attrs: nonlazybind uwtable
declare zeroext i1 @"_ZN4core3fmt3num53_$LT$impl$u20$core..fmt..LowerHex$u20$for$u20$i32$GT$3fmt17h19ab7be5b0fb7587E"(i32* noalias readonly align 4 dereferenceable(4), %"core::fmt::Formatter"* align 8 dereferenceable(64)) unnamed_addr #0

; core::fmt::Formatter::debug_upper_hex
; Function Attrs: nonlazybind uwtable
declare zeroext i1 @_ZN4core3fmt9Formatter15debug_upper_hex17h20623f52650bb644E(%"core::fmt::Formatter"* noalias readonly align 8 dereferenceable(64)) unnamed_addr #0

; core::fmt::num::<impl core::fmt::UpperHex for i32>::fmt
; Function Attrs: nonlazybind uwtable
declare zeroext i1 @"_ZN4core3fmt3num53_$LT$impl$u20$core..fmt..UpperHex$u20$for$u20$i32$GT$3fmt17hd8a7bd4ba29743b9E"(i32* noalias readonly align 4 dereferenceable(4), %"core::fmt::Formatter"* align 8 dereferenceable(64)) unnamed_addr #0

; core::fmt::num::imp::<impl core::fmt::Display for i32>::fmt
; Function Attrs: nonlazybind uwtable
declare zeroext i1 @"_ZN4core3fmt3num3imp52_$LT$impl$u20$core..fmt..Display$u20$for$u20$i32$GT$3fmt17hbb27e86dfb8ce1d4E"(i32* noalias readonly align 4 dereferenceable(4), %"core::fmt::Formatter"* align 8 dereferenceable(64)) unnamed_addr #0

; Function Attrs: nounwind nonlazybind uwtable
declare i32 @rust_eh_personality(i32, i32, i64, %"unwind::libunwind::_Unwind_Exception"*, %"unwind::libunwind::_Unwind_Context"*) unnamed_addr #2

; alloc::alloc::handle_alloc_error
; Function Attrs: noreturn nounwind nonlazybind uwtable
declare void @_ZN5alloc5alloc18handle_alloc_error17he602a36a7d59d201E(i64, i64) unnamed_addr #5

; Function Attrs: nounwind nonlazybind uwtable
declare noalias i8* @__rust_alloc(i64, i64) unnamed_addr #2

; Function Attrs: nounwind nonlazybind uwtable
declare void @__rust_dealloc(i8*, i64, i64) unnamed_addr #2

; std::io::stdio::_print
; Function Attrs: nonlazybind uwtable
declare void @_ZN3std2io5stdio6_print17h35ebd65662fa8b15E(%"core::fmt::Arguments"* noalias nocapture dereferenceable(48)) unnamed_addr #0

; Function Attrs: nonlazybind
define i32 @main(i32 %0, i8** %1) unnamed_addr #6 {
top:
  %_7.i = alloca i8*, align 8
  %2 = sext i32 %0 to i64
  %3 = bitcast i8** %_7.i to i8*
  call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %3)
  %4 = bitcast i8** %_7.i to void ()**
  store void ()* @_ZN2t34main17h33660e99b2ecbe28E, void ()** %4, align 8
  %_4.0.i = bitcast i8** %_7.i to {}*
; call std::rt::lang_start_internal
  %5 = call i64 @_ZN3std2rt19lang_start_internal17hf4abd869024c3270E({}* nonnull align 1 %_4.0.i, [3 x i64]* noalias readonly align 8 dereferenceable(24) bitcast ({ void (i8**)*, i64, i64, i32 (i8**)*, i32 (i8**)*, i32 (i8**)* }* @vtable.0 to [3 x i64]*), i64 %2, i8** %1)
  call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %3)
  %6 = trunc i64 %5 to i32
  ret i32 %6
}

attributes #0 = { nonlazybind uwtable "probe-stack"="__rust_probestack" "target-cpu"="x86-64" }
attributes #1 = { inlinehint nonlazybind uwtable "probe-stack"="__rust_probestack" "target-cpu"="x86-64" }
attributes #2 = { nounwind nonlazybind uwtable "probe-stack"="__rust_probestack" "target-cpu"="x86-64" }
attributes #3 = { norecurse nounwind nonlazybind readnone uwtable "probe-stack"="__rust_probestack" "target-cpu"="x86-64" }
attributes #4 = { argmemonly nounwind willreturn }
attributes #5 = { noreturn nounwind nonlazybind uwtable "probe-stack"="__rust_probestack" "target-cpu"="x86-64" }
attributes #6 = { nonlazybind "probe-stack"="__rust_probestack" "target-cpu"="x86-64" }
attributes #7 = { nounwind }
attributes #8 = { noinline }

!llvm.module.flags = !{!0, !1, !2}

!0 = !{i32 7, !"PIC Level", i32 2}
!1 = !{i32 7, !"PIE Level", i32 2}
!2 = !{i32 2, !"RtLibUseGOT", i32 1}
!3 = !{}
!4 = !{!5}
!5 = distinct !{!5, !6, !"_ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17h333ea9d4a60716ebE: %_1"}
!6 = distinct !{!6, !"_ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17h333ea9d4a60716ebE"}
!7 = !{!8}
!8 = distinct !{!8, !9, !"_ZN4core3fmt9Arguments6new_v117hc1127a6437d08baeE: argument 0"}
!9 = distinct !{!9, !"_ZN4core3fmt9Arguments6new_v117hc1127a6437d08baeE"}
!10 = !{!11}
!11 = distinct !{!11, !9, !"_ZN4core3fmt9Arguments6new_v117hc1127a6437d08baeE: %args.0"}
